package ilearn.seata.job.java8.account.dao;

import ilearn.seata.job.java8.account.entity.Points;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;

@Mapper
@Repository
public interface PointDao {

    @Select("select * from points where accId=#{accId}")
    Points findByAccId(String accId);
    @Update("update points set points=#{points} where accId=#{accId}")
    int update(Points points);
    @Insert("insert into points (accId,points) values(#{accId},#{points})")
    void insert(Points points);
}
